2 Returns true if point a is inside convex polygon p. Note
3 that if point a lies on the border of p it is considered
6 We assume p is convex! The result is useless if p is
9 bool insideConvexPolygon(const vector
<point
> &p
,
13 for (int i
=0; i
<n
; ++i
){
15 double z
= turn(p
[i
], p
[j
], a
);
20 }else if (z
== 0.0) return false;
21 if (mask
== 3) return false;